
/*
使用双重循环实现五子棋游戏棋盘绘制
* */
public class DrawCheckerboard{
    public static void main(String... args){
        char[] arr = {'a', 'b', 'c', 'd', 'e', 'f'};

        for(int i = 0; i <= 16; i++){
            if(i == 0){
                System.out.print("  ");
            }
            else if(i <= 10){
                System.out.print(" "+(i-1));
            }
            else{
                System.out.print(" "+arr[i-11]);
            }
            for (int j = 0; j< 16; j++){
                if(i==0){
                    if(j <= 9) {
                        System.out.print("  " + j);
                    }
                    else{
                        System.out.print("  "+ arr[j-10]);
                    }
                }
                else{
                    System.out.print("  +");
                }
            }
            System.out.print("\n");
        }
    }
}